package com.six.flower.controller

import com.six.library.model.ResultData
import com.six.library.model.ResultInfo
import org.springframework.web.bind.annotation.CrossOrigin
import org.springframework.web.bind.annotation.RequestBody
import org.springframework.web.bind.annotation.RequestMapping
import org.springframework.web.bind.annotation.ResponseBody
import org.springframework.web.bind.annotation.RestController


/*-*- coding:utf-8 -*-
 * @Author  : debi
 * @Time    : 10/24/22
 * @Software: IntelliJ IDEA
 */
@RestController
@RequestMapping("/test")
@CrossOrigin
class Test {
    @RequestMapping("/OK")
    fun OK(@RequestBody id: Int): ResultData {
        val data = ResultInfo.setData(id)
        println(data.toString())
        return data
    }

}